package com.douyin.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.douyin.entity.video.VideoStar;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

@Mapper
public interface VideoStarMapper extends BaseMapper<VideoStar> {
    @Select("select * from video_star where video_id = #{videoId} and user_id = #{userId}")
    VideoStar queryOne(Long videoId, Long userId);

    @Update("update video_star set is_deleted = #{isDeleted} where id = #{id}")
    void updateVideoStar(VideoStar videoStar);
}
